package com.shty.wd.utils.module.related;

import java.io.BufferedReader;
import java.io.FileInputStream;
import java.io.IOException;
import java.io.InputStream;
import java.io.InputStreamReader;
import java.util.Properties;

public class Resource {

	// Read the data in the dictionaries.
	public String getLocResource(String path) throws IOException{  
        //InputStream is=this.getClass().getResourceAsStream(path);   
		InputStream is = new FileInputStream(path);
        BufferedReader br=new BufferedReader(new InputStreamReader(is,"utf-8"));  
		String s="";  
		String line = "";				
		while ((line = br.readLine()) != null) {
			line = line.trim().toLowerCase();
			 s+= line+"|";
		}
		s = s.substring(0,s.length()-1);
		br.close();	
		is.close(); 
	    return s;	       
	} 	
}
